const ScenicSpot = require('../../model/scenicSpot/ScenicSpot')

function add(req,res){
  console.log(req.body)
  ScenicSpot.create(req.body, (err,result)=>{
    console.log(err)
    if(err){
      res.json({
        code:0,
        msg: '增加失败'
    })  
    }else{
      res.json({
        code:1,
        msg: '增加成功'
    })
    }
  })
  
}
module.exports = add